namespace DotNetNuke.Services.FileSystem
{
    using System;
    using System.Xml.Serialization;

    /// -----------------------------------------------------------------------------
    /// Project	 : DotNetNuke
    /// Class	 : FileInfo
    /// 
    /// -----------------------------------------------------------------------------
    /// <summary>
    /// Represents the File object and holds the Properties of that object
    /// </summary>
    /// <remarks>
    /// </remarks>
    /// <history>
    /// [DYNST]	2/1/2004	Created
    /// </history>
    /// -----------------------------------------------------------------------------
    [XmlRoot("file", IsNullable=false)]
    public class FileInfo
    {
        private string _ContentType;
        private string _Extension;
        /// -----------------------------------------------------------------------------
        /// <summary>
        /// The Primary Key ID of the current File, as represented within the Database table named "Files"
        /// </summary>
        /// <remarks>
        /// This Integer Property is passed to the FileInfo Collection
        /// </remarks>
        /// <history>
        /// [DYNST]	2/1/2004	Created
        /// </history>
        /// -----------------------------------------------------------------------------
        private int _FileId;
        private string _FileName;
        private string _Folder;
        private int _Height;
        private int _PortalId;
        private int _Size;
        private int _Width;

        [XmlElement("contenttype")]
        public string ContentType
        {
            get
            {
                return this._ContentType;
            }
            set
            {
                this._ContentType = value;
            }
        }

        [XmlElement("extension")]
        public string Extension
        {
            get
            {
                return this._Extension;
            }
            set
            {
                this._Extension = value;
            }
        }

        [XmlIgnore]
        public int FileId
        {
            get
            {
                return this._FileId;
            }
            set
            {
                this._FileId = value;
            }
        }

        [XmlElement("filename")]
        public string FileName
        {
            get
            {
                return this._FileName;
            }
            set
            {
                this._FileName = value;
            }
        }

        [XmlIgnore]
        public string Folder
        {
            get
            {
                return this._Folder;
            }
            set
            {
                this._Folder = value;
            }
        }

        [XmlElement("height")]
        public int Height
        {
            get
            {
                return this._Height;
            }
            set
            {
                this._Height = value;
            }
        }

        [XmlIgnore]
        public int PortalId
        {
            get
            {
                return this._PortalId;
            }
            set
            {
                this._PortalId = value;
            }
        }

        [XmlElement("size")]
        public int Size
        {
            get
            {
                return this._Size;
            }
            set
            {
                this._Size = value;
            }
        }

        [XmlElement("width")]
        public int Width
        {
            get
            {
                return this._Width;
            }
            set
            {
                this._Width = value;
            }
        }
    }
}

